﻿<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>

<fmt:setBundle basename="ApplicationMessage" />
<fmt:setLocale value="zh_CN" />

<!DOCTYPE html>
<html lang="zh-CN">
  <%@ include file="/WEB-INF/include/script.jsp"%>

<head>

  <%@ include file="/WEB-INF/include/meta.jsp"%>
  <%@ include file="/WEB-INF/include/css.jsp"%>
 
</head>

<body class="ms-theme-blue">

  <%@ include file="/WEB-INF/include/header.jsp"%>
  <%@ include file="/WEB-INF/include/submenu.jsp"%>

  <div class="container-fluid umu-container has-umu-sidemenu">
    <div class="umu-breadcrumb">
      <div class="breadcrumb">学习项目报表</div>
    </div>
    
    <form class="form-horizontal ms-form modal-search-form" role="form" method="GET" action="${ctx.host}/project-report" data-validate="true">
      <input type="hidden" name="filter" value="true">

    <div class="panel-default beast-panel beast-panel-layout">

      <div class="panel-body">
        <div class="col-xs-12 beast-panel-layout-right">

    		<div class="ms-content-layout">
		<div class="form-horizontal ms-form form-personal-info">

             <div class="form-group  ms-form-group">
	          <label class="control-label col-xs-2">项目名称：</label>
	          <div class="col-xs-2">
	            <input type="text" class="form-control" name="name" value="" placeholder="项目名称" data-validate="required" autocomplete="off" tabindex="2"/>
	          </div>
	          <label class="control-label col-xs-2"><span class="text-red">*</span>事业部：</label>
				<div class="col-xs-2">	              
					<select class="select2 form-control" name="departmentId" data-validate="required" id="selDepartment" tabindex="7">
		                <option value="">全部</option>
		                <c:forEach items="${departmentList}" var="department">
                          <c:if test="${department.id != 1}">
                            <option value="${department.id}">${department.name}</option>
                          </c:if>
		                </c:forEach>
		            </select>
	            </div>
	        </div>
            <div class="form-group  ms-form-group">
	          <label class="control-label col-xs-2"><span class="text-red">*</span>一级分类：</label>
	            <div class="col-xs-2">
	              <select class="select2 form-control" name="firstCategoryId" data-validate="required" id="selFirstCat"  tabindex="2">
	              <option value="">全部</option>
	                <c:forEach items="${allCatMap}" var="allCat">
	                  <option value="${allCat.key}">${allNameIdMap[allCat.key]}</option>
	                </c:forEach>
	              </select>
	            </div>
	          <label class="control-label col-xs-2"><span class="text-red">*</span>二级分类：</label>
	            <div class="col-xs-2">
	              <select class="select2 form-control" name="secondCategoryId" data-validate="required" id="selSecondCat" tabindex="3">
	                <option></option>
	              </select>
	            </div>
	        </div>
            <div class="form-group  ms-form-group">
	          <label class="control-label col-xs-2">项目负责人：</label>
	          <div class="col-xs-2">
	            <input type="text" class="form-control" name="projectLead" value="" placeholder="项目负责人" data-validate="required" autocomplete="off" tabindex="3"/>
	          </div>
	        </div>        
            <div class="form-group  ms-form-group">
	          <label class="control-label col-xs-2">开始时间从：</label>
	          <div class="col-xs-2">
	            <input type="text" class="form-control" name="beginDateFrom" value="" placeholder="开始时间" data-validate="required" autocomplete="off" tabindex="3"/>
	          </div>
	          <label class="control-label col-xs-2">至：</label>
	          <div class="col-xs-2">
	            <input type="text" class="form-control" name="beginDateTo" value="" placeholder="开始时间" data-validate="required" autocomplete="off" tabindex="3"/>
	          </div>
	        </div>   
            <div class="form-group  ms-form-group">
	          <label class="control-label col-xs-2">结束时间从：</label>
	          <div class="col-xs-2">
	            <input type="text" class="form-control" name="endDateFrom" value="" placeholder="结束时间" data-validate="required" autocomplete="off" tabindex="3"/>
	          </div>
	          <label class="control-label col-xs-2">至：</label>
	          <div class="col-xs-2">
	            <input type="text" class="form-control" name="endDateTo" value="" placeholder="结束时间" data-validate="required" autocomplete="off" tabindex="3"/>
	          </div>
	        </div> 
      </div>
      </div>
      </div>

      </div>
      <div class="modal-footer ms-modal-footer">
        <button type="submit" class="btn btn-shadow-success btn-shadow umu-btn">查询</button>
        <button type="button" class="btn btn-shadow-default btn-shadow umu-btn" data-dismiss="modal">取消</button>
      </div>

    </div>
</form>
  </div>

  <%@ include file="/WEB-INF/include/footer.jsp"%>

</body>
<script type="text/javascript">
var catMap=new Array();
var allNameIdMap=new Array();
<c:forEach items="${allNameIdMap}" var="map">
	allNameIdMap['<c:out value="${map.key}"></c:out>']='<c:out value="${map.value}"></c:out>';
</c:forEach>


<c:forEach items="${allCatMap}" var="allCat">
	catMap['<c:out value="${allCat.key}"></c:out>'] = '<c:out value="${allCat.value}"></c:out>';
</c:forEach>



</script> 

<script type="text/javascript">
        require([ 'page/report/report' ], function(page) {
            page.init();
            $("#selFirstCat").trigger('change');
            
        });
        
</script>
</html>